package cn.wsalix.spring.task;

import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.scheduling.annotation.Scheduled;
import org.springframework.stereotype.Component;

import cn.wsalix.sys.service.DailyRecordService;

/**
 * @author jskyme
 *
 */
@Component("dailyTask")
public class DailyTask {
	protected Logger logger = LoggerFactory.getLogger(getClass());
	@Autowired
	private DailyRecordService dailyRecordService;
	@Scheduled(cron = "0 0 0 * * ?")
	public void doJob() {
		logger.info("..............doJob.............");
		dailyRecordService.newDay();
		//saleDailyService.newDay();
	}

}